<?php include "inc/header.inc"; ?>

<?php

if(isset($_REQUEST['Submit']))
{
	$qst1 = limpa_caracter($_REQUEST['qst1']);

	if(!isset($_REQUEST['qst2'])){ $qst2=""; } else { $qst2 = $_REQUEST['qst2']; }

	$qst2_est = limpa_caracter($_REQUEST['qst2_est']);


	if(!isset($_REQUEST['qst3'])){ $qst3=""; } else { $qst3 = $_REQUEST['qst3']; }
	if(!isset($_REQUEST['qst4'])){ $qst4=""; } else { $qst4 = $_REQUEST['qst4']; }
	if(!isset($_REQUEST['qst5'])){ $qst5=""; } else { $qst5 = $_REQUEST['qst5']; }

	$qst6 = limpa_caracter($_REQUEST['qst6']);

	if(!isset($_REQUEST['qst7'])){ $qst7=""; } else { $qst7 = $_REQUEST['qst7']; }

	if(!isset($_REQUEST['qst8'])){ $qst8=""; } else { $qst8 = $_REQUEST['qst8']; }

	$qst8_topics = limpa_caracter($_REQUEST['qst8_topics']);


	//try {

	$strSql = "insert into db_survey_questionnaire ";
	$strSql .= "(qst1, qst2, qst2_est, qst3, qst4, qst5, qst6, qst7, qst8, qst8_topics, dat_answer)";
	$strSql .= " values ( '$qst1', '$qst2', '$qst2_est', '$qst3', '$qst4', '$qst5', '$qst6', '$qst7', '$qst8', '$qst8_topics',now())";

	//echo $strSql;
	$rs = execQuery($strSql);

	if($rs)
	{
		echo "<script language='javascript'>alert('Register has been inserted!');</script>";
	}
	else
	{
		echo "<script language='javascript'>alert('Error: Register has not been inserted!\\nPlease, check your data and Submit the form again.');history.go(-1);</script>";
	}




}
?>



<div id="designologuefp">



<h3>Survey Questionnaire Prototype</h3>
<form action="" name="surveyform" method="post">
<ul>


	<li><strong>1 - Name of your CBS:</strong><br />
	<input name="qst1" type="text" style="width: 690px;" maxlength="100" />

	</li>


	<li><strong>2 - Approximately how long did it take you to complete the
	survey(s)?</strong><br />
	<input name="qst2" type="radio" value="10 to 15 minutes" /> 10 to 15
	minutes<br />
	<input name="qst2" type="radio" value="15 to 20 minutes" /> 15 to 20
	minutes<br />
	<input name="qst2" type="radio" value="20 to 30 minutes" /> 20 to 30
	minutes<br />
	<input name="qst2" type="radio" value="30 to 40 minutes" /> 30 to 40
	minutes<br />
	<input name="qst2" type="radio" value="40 to 50 minutes" /> 40 to 50
	minutes<br />
	<input name="qst2" type="radio" value="50 minutes to 1 hour" /> 50
	minutes to 1 hour<br />
	<input name="qst2" type="radio" value="More than 1 hour" /> More than 1
	hour (if so, estimate how long <input name="qst2_est" type="text"
		size="5" maxlength="5" />) <br />

	</li>


	<li><strong>3 - In your opinion, was the survey:</strong><br />
	<input name="qst3" type="radio" value="Boring" /> Boring<br />
	<input name="qst3" type="radio" value="Somewhat interesting" />
	Somewhat interesting<br />
	<input name="qst3" type="radio" value="Very interesting" /> Very
	interesting<br />


	</li>


	<li><strong>4 - In your opinion, was the survey:</strong><br />
	<input name="qst4" type="radio" value="Too long" /> Too long<br />
	<input name="qst4" type="radio" value="Too short" /> Too short<br />
	<input name="qst4" type="radio" value="Reasoneble" /> Reasoneble<br />


	</li>

	<li><strong>5 - Were the instructions for answering and completing the
	survey:</strong><br />
	<input name="qst5" type="radio" value="Clear" /> Clear (skip to item 7)<br />
	<input name="qst5" type="radio" value="Confusing" /> Confusing (go to
	item 6)<br />
	<input name="qst5" type="radio" value="No opinion" /> No opinion (skip
	to item 7)<br />


	</li>


	<li><strong>6 - Please describe how the instructions were confusing or
	what problems you had completing the questions. You can also write
	directly on survey to indicate any confusion/problems.</strong><br />
	<textarea name="qst6" style="width: 690px; height: 100px"></textarea></li>


	<li><strong>7 - Were there any questions or topics in the survey that
	were confusing to you?</strong><br />
	<input name="qst7" type="radio" value="Yes" /> Yes (skip to item 8)<br />
	<input name="qst7" type="radio" value="No" /> No (go to item 9)<br />
	<input name="qst7" type="radio" value="Not sure" /> Not sure<br />


	</li>

	<li><strong>8 - Briefly describe wich questions or topics were
	confusing (including questions numbers when applicable).</strong><br />
	<br />
	<strong>Questions:</strong><br />
	<input name="qst8" type="checkbox" value="Question 1" />Question 1
	&nbsp; <input name="qst8" type="checkbox" value="Question 5" />Question
	5<br />
	<input name="qst8" type="checkbox" value="Question 2" />Question 2
	&nbsp; <input name="qst8" type="checkbox" value="Question 6" />Question
	6<br />
	<input name="qst8" type="checkbox" value="Question 3" />Question 3
	&nbsp; <input name="qst8" type="checkbox" value="Question 7" />Question
	7<br />
	<input name="qst8" type="checkbox" value="Question 4" />Question 4
	&nbsp; <input name="qst8" type="checkbox" value="Question 8" />Question
	8<br />

	<br />
	<strong>Topics:</strong><br />
	<textarea name="qst8_topics" style="width: 690px; height: 100px"></textarea>


	</li>


	<li style="text-align: center"><input type="submit" name="Submit"
		value="Submit" /> &nbsp; <input type="reset" name="Reset"
		value="Reset" /></li>

</ul>
</form>

</div>

<?php include "inc/footer.inc"; ?>

<script language="javascript">
function notImplemented()
{
	alert("This feature is not implemented yet!");
}
</script>
